package _20FileReader读取字符数组;

import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;

public class Demo {
    public static void main(String[] args) throws IOException {
        FileReader fileReader = new FileReader("D:\\黑马java培训班\\代码\\itcast\\JavaSE\\day10\\abd\\aa\\a.txt");
        char[] chars=new char[1024];
        int readLength;

        while ((readLength=fileReader.read(chars))!=-1){
            System.out.print(new String(chars,0,readLength));
        }

    }
}
